# -*- encoding:utf-8 -*-
from mako import runtime, filters, cache
UNDEFINED = runtime.UNDEFINED
__M_dict_builtin = dict
__M_locals_builtin = locals
_magic_number = 5
_modified_time = 1285368037.9675629
_template_filename='/Users/joeldunham/old/onlinelinguisticdatabase/templates/derived/form/export.html'
_template_uri='/derived/form/export.html'
_template_cache=cache.Cache(__name__, _modified_time)
_source_encoding='utf-8'
from webhelpers.html import escape
_exports = ['heading']


def _mako_get_namespace(context, name):
    try:
        return context.namespaces[(__name__, name)]
    except KeyError:
        _mako_generate_namespaces(context)
        return context.namespaces[(__name__, name)]
def _mako_generate_namespaces(context):
    # SOURCE LINE 2
    ns = runtime.Namespace(u'exporter', context._clean_inheritance_tokens(), templateuri=u'/base/exporter.html', callables=None, calling_uri=_template_uri, module=None)
    context.namespaces[(__name__, u'exporter')] = ns

def _mako_inherit(template, context):
    _mako_generate_namespaces(context)
    return runtime._inherit_from(context, u'/base/index.html', _template_uri)
def render_body(context,**pageargs):
    context.caller_stack._push_frame()
    try:
        __M_locals = __M_dict_builtin(pageargs=pageargs)
        _import_ns = {}
        _mako_get_namespace(context, u'exporter')._populate(_import_ns, [u'*'])
        h = _import_ns.get('h', context.get('h', UNDEFINED))
        c = _import_ns.get('c', context.get('c', UNDEFINED))
        app_globals = _import_ns.get('app_globals', context.get('app_globals', UNDEFINED))
        __M_writer = context.writer()
        # SOURCE LINE 1
        __M_writer(u'\n')
        # SOURCE LINE 2
        __M_writer(u'\n\n')
        # SOURCE LINE 14
        __M_writer(u'\n\n<p>Choose export type</p>\n\n<form action="')
        # SOURCE LINE 18
        __M_writer(escape(h.url_for(controller='form', action='exporter', id=c.id)))
        __M_writer(u'" ')
        # SOURCE LINE 19
        __M_writer(u'      method="post">\n    <ul>    \n')
        # SOURCE LINE 21
        for exportOption in app_globals.exportOptions:
            # SOURCE LINE 22
            __M_writer(u'        <li class="radioLI">')
            __M_writer(escape(h.radio(name='exportType', \
        value=exportOption[0], label=exportOption[1])))
            # SOURCE LINE 23
            __M_writer(u'</li>    \n')
            pass
        # SOURCE LINE 25
        __M_writer(u'    </ul>\n    <div>')
        # SOURCE LINE 26
        __M_writer(escape(h.submit(value="Export", name='submit')))
        __M_writer(u'</div>\n</form>\n')
        return ''
    finally:
        context.caller_stack._pop_frame()


def render_heading(context):
    context.caller_stack._push_frame()
    try:
        _import_ns = {}
        _mako_get_namespace(context, u'exporter')._populate(_import_ns, [u'*'])
        c = _import_ns.get('c', context.get('c', UNDEFINED))
        __M_writer = context.writer()
        # SOURCE LINE 4
        __M_writer(u'\n')
        # SOURCE LINE 5
        if c.id:
            # SOURCE LINE 6
            if c.id == 'memory':
                # SOURCE LINE 7
                __M_writer(u'        <h1 class="heading">Export Forms in Memory</h1>\n')
                # SOURCE LINE 8
            else:
                # SOURCE LINE 9
                __M_writer(u'        <h1 class="heading">Export Form ')
                __M_writer(escape(c.id))
                __M_writer(u'</h1>\n')
                pass
            # SOURCE LINE 11
        else:
            # SOURCE LINE 12
            __M_writer(u'    <h1 class="heading">Export All Form Search Results</h1>\n')
            pass
        return ''
    finally:
        context.caller_stack._pop_frame()


